1. Field of the Invention
The present invention relates to computer-based graphics systems and, in particular, discloses a colour generation and mixing system capable of operation at video data rates at real-time.
2. Description of the Related Art
U.S. patent Ser. No. 08/053,373, filed Apr. 28, 1993 entitled "A Real-Time Object Based Graphics System", claiming priority from Australian Patent Application No. PL 2147, filed Apr. 29, 1992. Lodged concurrently herewith and the disclosure of which is hereby incorporated by reference, discloses a system which provides for the rendering of object-based graphic images in real-time at video data rates.
An example of part of such a system is shown in FIG. 1 where part of a real-time object (RTO) based graphics systems 1 is shown which includes an RTO processor 2 and a colour look-up table (CLUT) 3. The RTO processor 2 and the CLUT 3 connect to various other components (not illustrated) of the system 1 which are seen in the above crossreferenced patent application. The RTO processor 2 is configured to be input with data describing object outlines, and is able to process the outlines of multiple objects for rendering in scan line and pixel dimensions. However, the RTO processor 2 does not attempt to generate colours, which are predefined by the object outlines. In this manner, the RTO processor 2 outputs colour levels of objects, which are synchronised with line and pixel dimensions, that can be externally mapped to any desired colour using the CLUT 3. As seen in FIG. 1, the RTO processor 2 outputs 8 bits of level and effects data which can be termed as level output data 4.
The 8-bit output 4 from the RTO processor 2 comprises 6 bits of LEVEL data and 2 bits of EFFECTS data and can be used to determine the colour at a current position provided by line and pixel dimensions which are synchronised with a display (not illustrated) such as a VDU or a printer. The output data 4 is input to the CLUT 3 wherein the level output data 4 acts as an address for the CLUT 3 which outputs 24-bit RGB data 5 to the display. It will be apparent to those skilled in the art that the CLUT 3 need not contain additive RGB data which is generally used in video devices but can store CMYK (cyan, magenta, yellow and black) data which is a subtractive colour space used in printers such as the CANON CLC 500 Colour Laser Copier. Alternatively, composite video comprising luminance (Y) and chrominance values (Cr and Cb) can also be used.
In the configuration of FIG. 1, the CLUT 3 is arranged to have four sets of 64 entries in which the two effects bits select the appropriate set, and the level bits select the appropriate entry in each set. For example, the first set of 64 entries can be standard colours and the remaining sets can be variations of these colours that can be used to illustrate shadow layers, or other visual effects.
FIGS. 2, 3 and 4 show three examples of an image output that can be created using the RTC system 1. The level data output 4 from the RTO processor 2 follows a simple rule in which:
EFFECTS equals the highest active priority level's effects bits (zero if no levels are active); and PA1 LEVEL equals the highest opaque active priority level (zero if no opaque levels are active). PA1 where no LEVELS are active, the output is LEVEL 0, EFFECTS 0; PA1 within the part of rectangle A that does not intersect with rectangle B, the highest active LEVEL is 10. The effects for LEVEL 10 is 0. The highest active opaque is also LEVEL 10 (as EFFECTS 0 is opaque). Therefore, the output for this section is LEVEL 10, EFFECTS 0; PA1 within the part of the rectangle B that does not intersect with rectangle A, the highest active LEVEL is 20. The effects for LEVEL 20 is 2. There are no active opaque LEVELS (as level 20 has EFFECTS 2 which is fall-through), so the output for this section if LEVEL 0, EFFECTS 2; PA1 Within the intersection of rectangles A and B, the highest active LEVEL is 20.
Thus, the priority level determines what will be shown for any given position. When a number of objects are all active at the same pixel location, the highest priority opaque object is displayed using the effects mode of the highest active priority, whether it is opaque or not.
Firstly, in considering the example of FIG. 2, rectangle A has a LEVEL of 10 and an EFFECTS of 0. Rectangle B has LEVEL 20 and EFFECTS 2. When the RTO processor 2 processes the object data to render the rectangles A and B, it implements an odd/even fill rule to fill the objects. That is, when it encounters an object edge at LEVEL N, the RTO processor 2 activates the fill for that level, and when it encounters the next edge, it deactivates the fill for that level. The output from the RTO processor 2 therefore depends on the highest active level's effects bits, and the highest active opaque level's level.
The RTO processor 2 is configured to implement transparency and when transparency is disabled, the effects modes 0, 1, 2 and 3 are all opaque. Accordingly, the highest active priority level will always be the highest active opaque level as all effects are opaque.
FIG. 3 illustrates the displayed image when transparency is disabled using inputs identical to those of FIG. 2. The net effect is that the objects drawn at higher levels (e.g. rectangle B) completely obscure objects drawn at lower levels (e.g. rectangle A).
When transparency is enabled in the RTTO processor 2, effects modes 0 and 1 are opaque, and effects modes 2 and 3 are fall-through. The output from the RTO processor 2 can then be seen in FIG. 4 and explained as follows:
The EFFECTS for level 20 is 2. The highest active opaque LEVEL is 10 (as LEVEL 20's EFFECTS 2 is fall-through, but LEVEL 10's EFFECTS 0 is opaque).
Therefore the output for this section is LEVEL 10, EFFECTS 2.
The net effect of the above, is that the objects drawn in fall-through effects modes cause a fall-through to the first opaque level below them. The output retains the effects mode of the fall-through level. Rectangle B is effectively a transparent rectangle, and the effects bits for it will be active, while it is the highest active level. At the intersection point, instead a level 10 effects 0, the effect is level 10 effects 2, which causes a look-up to a different colour, for example a darker version of level 10 effects 0, which would give a shadow effect.
The RTO system 1, FIG. 1, requires that the CLUT 3 is updated regularly so that the correct colour is stored in each entry. This is performed by connecting the CLUT 3 to a host processor which can alter the contents of the CLUT 3, for example on an image basis allowing any 256 colours in the palette of the CLUT 3.
By altering the contents of the CLUT 3 unlimited complexity for colour and effects can be provided merely by updating each entry using software. However, limits of update and calculation time in a real-time environment limit the visual effects that the system I is capable of producing.
Accordingly, it is an object of the present invention to substantially overcome, or ameliorate, the problems of updating the colour entries in the CLUT 3.